﻿@model CSEPT.Models.RegisterViewModel
@{
    ViewBag.Title = "Register for " + Model.bib.RegisteredEvent.Title;
}
<h2>Registration for: @Model.bib.RegisteredEvent.Title</h2>
<form class="col-xs-12 col-sm-8 col-sm-offset-2 col-md-6 col-md-offset-3 col-lg-4 col-lg-offset-4" id="BibRegistration" action="@Url.Action("Update", "Register")" method="post">
    @Html.HiddenFor(model => model.bib.ID)
    @Html.HiddenFor(model => model.bib.RegisteredUser.ID, new { @Value = Model.CurrUser.ID })
    @Html.HiddenFor(model => model.bib.RegisteredEvent.ID)
    <div class="col-xs-12 form-group">
        <label class="control-label">Bib Number</label>
        @Html.TextBoxFor(model => model.bib.BibNumber, new { @placeholder = "Bib Number", @class = "form-control required" })
    </div>
    <div class="col-xs-12">
        @if (Model.bib.ID != 0)
        {
            <div class="btn-group">
                <a class="btn btn-lg btn-danger rounded" onclick="$(this).removeClass('rounded'); $(this).siblings('.btn').slideDown(200)" href="#">UnRegister?</a>
                <a class="btn btn-lg btn-danger" href="@Url.Action("Delete", "Register", new {@ID = Model.bib.ID})" style="display:none">Yes</a>
            </div>
        }
        <button class="btn btn-lg btn-primary pull-right">Submit</button>
    </div>

</form>